package com.dongnam.quanly.common.model;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.Id;
import javax.persistence.Table;

import com.dongnam.quanly.common.model.enumtype.LoaiPhieu;

@Entity
@Table(name = "PhieuNhapXuat")
public class PhieuNhapXuat extends BaseEntity {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	@Id
	@Column(name = "SoChungTu", length = 30)
	private String soChungTu;

	@Column(name = "KhoHang")
	private String khoHang;

	@Column(name = "DonHang")
	private String donHang;

	@Column(name = "NgayLap")
	private Date ngayLap;

	@Column(name = "NhanVien")
	private String nguoiLap;

	@Column(name = "LoaiPhieu", length = 30)
	@Enumerated(EnumType.STRING)
	private LoaiPhieu loaiPhieu;

	@Column(name = "SoTaiKhoanCo")
	private String soTaiKhoanCo;

	@Column(name = "SoTaiKhoanNo")
	private String soTaiKhoanNo;

	@Column(name = "CoHoaDon")
	private boolean coHoaDon;

	public PhieuNhapXuat() {
		super();
		// TODO Auto-generated constructor stub
	}

	public PhieuNhapXuat(PhieuNhapXuat pnx) {
		super();
		this.soChungTu = pnx.soChungTu;
		this.khoHang = pnx.khoHang;
		this.donHang = pnx.donHang;
		this.ngayLap = pnx.ngayLap;
		this.nguoiLap = pnx.nguoiLap;
		this.loaiPhieu = pnx.loaiPhieu;
		this.soTaiKhoanCo = pnx.soTaiKhoanCo;
		this.soTaiKhoanNo = pnx.soTaiKhoanNo;
		this.coHoaDon = pnx.coHoaDon;
	}

	public String getSoChungTu() {
		return soChungTu;
	}

	public void setSoChungTu(String soChungTu) {
		this.soChungTu = soChungTu;
	}

	public Date getNgayLap() {
		return ngayLap;
	}

	public void setNgayLap(Date ngayLap) {
		this.ngayLap = ngayLap;
	}

	public LoaiPhieu getLoaiPhieu() {
		return loaiPhieu;
	}

	public void setLoaiPhieu(LoaiPhieu loaiPhieu) {
		this.loaiPhieu = loaiPhieu;
	}

	public String getSoTaiKhoanCo() {
		return soTaiKhoanCo;
	}

	public void setSoTaiKhoanCo(String soTaiKhoanCo) {
		this.soTaiKhoanCo = soTaiKhoanCo;
	}

	public String getSoTaiKhoanNo() {
		return soTaiKhoanNo;
	}

	public void setSoTaiKhoanNo(String soTaiKhoanNo) {
		this.soTaiKhoanNo = soTaiKhoanNo;
	}

	public boolean isCoHoaDon() {
		return coHoaDon;
	}

	public void setCoHoaDon(boolean coHoaDon) {
		this.coHoaDon = coHoaDon;
	}

	public String getKhoHang() {
		return khoHang;
	}

	public void setKhoHang(String khoHang) {
		this.khoHang = khoHang;
	}

	public String getDonHang() {
		return donHang;
	}

	public void setDonHang(String donHang) {
		this.donHang = donHang;
	}

	public String getNguoiLap() {
		return nguoiLap;
	}

	public void setNguoiLap(String nguoiLap) {
		this.nguoiLap = nguoiLap;
	}

}
